package com.heima.mapper;

import com.github.pagehelper.Page;
import com.heima.pojo.entity.VmType;
import com.heima.result.PageResult;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface VmTypeMapper {
    @Select("select * from tb_vm_type where type_id=#{vmType}")
    VmType selectVM(Integer vmType);

    Page<VmType> selectType(String name);


    int add(VmType vmType);

    int update(VmType vmType);

    @Delete("delete from tb_vm_type where type_id=#{typeId}")
    int delete(Integer typeId);
}
